package org.cuatrovientos.erp.model;


import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import javax.validation.constraints.Min;

public class Product {


private int id;

@Size(min=2,max=50,message="{product.name.error}")
private String name;

@Size(min=2,max=100,message="{product.description.error}")
private String description;

@NotNull(message="{product.price.error}")
private float price;

@NotNull(message="{product.idproduct.error}")
private int idproduct;

public Product(int id, String name, String description, float price,
		int idproduct) {
	this.id = id;
	this.name = name;
	this.description = description;
	this.price = price;
	this.idproduct = idproduct;
}

public Product() {
}

/**
 * @return the id
 */
public int getId() {
	return id;
}

/**
 * @param id the id to set
 */
public void setId(int id) {
	this.id = id;
}

/**
 * @return the name
 */
public String getName() {
	return name;
}

/**
 * @param name the name to set
 */
public void setName(String name) {
	this.name = name;
}

/**
 * @return the description
 */
public String getDescription() {
	return description;
}

/**
 * @param description the description to set
 */
public void setDescription(String description) {
	this.description = description;
}

/**
 * @return the price
 */
public float getPrice() {
	return price;
}

/**
 * @param price the price to set
 */
public void setPrice(float price) {
	this.price = price;
}

/**
 * @return the idproduct
 */
public int getIdproduct() {
	return idproduct;
}

/**
 * @param idproduct the idproduct to set
 */
public void setIdproduct(int idproduct) {
	this.idproduct = idproduct;
}



}
